
div.tab[data-name='support'] {

  p {
    line-height: 150%;
  }

  p.notice {
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    padding-top: 15px;
    margin: 15px 0;
  }

  section.form {
    position: relative;

    &.hidden {
      display: none;

      + p.error {
        @include mask('icon-info', $colorNotice, 48px);
        position: relative;
        text-align: center;
        background: $bodyBackground;
        line-height: 150%;
        padding: 90px 30px 30px;
        margin: 0 0 10px 0;

        &::before {
          pointer-events: none;
          -webkit-mask-position-y: 20px;
        }

        > a {
          display: inline-block;
          margin: 10px 0 0 0;
          font-weight: $__fontWeightBold;
          color: $mainColor2;
        }
      }
    }

    div.mailWrapper {
      display: grid;
      align-items: center;
      grid-template-columns: auto 1fr;
      grid-gap: 10px;
      font-size: 90%;

      > label {
        display: block;
        font-weight: $__fontWeightNormal;
        font-style: italic;

        &::after {
          content: ":";
        }
      }

      input[type='email'] {
        margin: 0;
        font-size: 90%;
        height: 24px;
        width: 180px;
      }
    }


    button[type="submit"] {
      @extend %highlightButton;
    }

    textarea {
      resize: vertical;
      height: 200px;
      min-height: 200px;
    }

    div.upload {
      @extend %button;
      margin: 20px 0;

      > span {
        @include mask('settings/icon-screenshot', $textColorInverted, 20px);
        position: relative;
        padding: 0 3px 0 28px;

        &::before {
          -webkit-mask-position-x: 0;
        }
      }

      > input[type='file'] {
        position: absolute;
        top: 0;
        left: -900%;
        width: 1000%;
        height: 100%;
        cursor: pointer;
      }
    }
  }

  ul.uploadedFiles {

    > li {
      position: relative;
      padding: 12px 0;
      border-top: 1px solid rgba(0, 0, 0, 0.1);

      > img {
        display: inline-block;
        vertical-align: middle;
        width: 80px;
      }

      > span {
        display: inline-block;
        margin: 0 0 0 10px;
        width: calc(100% - 80px - 10px - 24px);
        white-space: nowrap;
        text-overflow: ellipsis;
        overflow: hidden;
      }

      > a.close {
        @include mask('icon-close', $textColor, 16px);
        position: absolute;
        top: 0;
        bottom: 0;
        right: 0;
        margin: auto;
        display: block;
        width: 22px;
        height: 22px;
        cursor: pointer;
        border-radius: 50%;
        transition: background-color 0.3s;

        &:hover {
          background-color: rgba(0, 0, 0, 0.1);
        }
      }
    }
  }

  @mixin suggestion {
    transition: opacity 0.2s, height 0.3s, padding 0.3s, margin 0.3s;

    &.hidden {
      @extend %hidden;
    }

    &.noHeight {
      height: 0 !important;
      padding-top: 0;
      padding-bottom: 0;
      margin: 0;
    }
  }

  div.faq {
    transition: opacity 0.5s;

    &.hidden {
      display: none;
    }

    &.loading {
      @extend %hidden;
      transition: none;
    }

    > h2 {
      margin-bottom: 30px;
    }

    > div.suggestion {
      position: relative;
      width: 100%;
      user-select: text;
      @include suggestion;

      + div.suggestion {
        border-top: 1px solid rgba(0, 0, 0, 0.1);
        margin-top: 15px;
        padding-top: 15px;
      }

      > strong {
        display: inline-block;
        font-size: 120%;
        font-weight: $__fontWeightNormal;
        line-height: 150%;
        padding: 5px 0;
        cursor: pointer;
      }

      > p {
        font-size: 90%;
        background: $bodyBackground;
        border-radius: 0 0 10px 10px;
        transition: opacity 0.3s, margin 0.5s, padding 0.5s;
        @extend %hidden;

        > a {
          display: inline-block;
          padding: 2px 7px;
          font-weight: $__fontWeightMedium;
          color: $mainColor2;
          border-radius: 5px;
          margin: 0 4px;
          cursor: pointer;
          transition: background 0.5s;

          &:hover {
            background: rgba($mainColor2, 0.2);
          }
        }

        &[data-type='answer'] {
          @extend %visible;
          margin-bottom: 15px;
          padding: 3px 0 7px;
          transition: opacity 0.3s 0.3s, margin 0.5s, padding 0.5s;
        }
      }

      > div.answer {
        @include bubble;
        @include suggestion;
        border-bottom-left-radius: 0;
        border-bottom-right-radius: 0;
      }
    }
  }

  div.suggestedAnswers {
    background: none !important;
    box-shadow: none !important;
    padding: 10px 10px 80px 10px !important;
    overflow: hidden;
    display: flex;
    flex-flow: column;
    justify-content: flex-end;
    align-items: flex-end;
    transform: translate3d(0, 20px, 0);
    transition: opacity 0.3s, transform 0.3s;
    @extend %hidden;

    &.visible {
      @extend %visible;
      transform: translate3d(0, 0, 0);
    }

    @media (min-width: 901px) {

      &::before {
        content: "";
        position: absolute;
        display: block;
        top: 0;
        left: 0;
        width: 100%;
        height: 70px;
        pointer-events: none;
        background: linear-gradient(to bottom, $bodyBackground 0%, transparent 100%);
        z-index: 2;
      }
    }

    > span.icon {
      @include mask('settings/support', $textColorInverted, 36px);
      position: absolute;
      bottom: 10px;
      right: 12px;
      width: 64px;
      height: 64px;
      border-radius: 50%;
      background: linear-gradient(45deg, $mainColor2 0%, $mainColor3 100%);
      box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.2);
    }

    > a {
      @include mask('settings/icon-feedback', $textColor, 14px);
      position: absolute;
      bottom: 32px;
      left: 17px;
      font-size: 120%;
      padding-left: 22px;
      cursor: pointer;
      display: none;

      &::before {
        -webkit-mask-position: left center;
      }
    }

    > div.suggestion {
      position: relative;
      width: 100%;
      background: $contentBackground;
      filter: drop-shadow(0 8px 8px rgba(0, 0, 0, 0.1));
      border-radius: 10px;
      margin-bottom: 20px;
      padding: 10px 15px;
      user-select: text;
      @include suggestion;

      &:last-of-type::before {
        content: "";
        position: absolute;
        bottom: -32px;
        right: 20px;
        border: 16px solid transparent;
        border-top-color: $contentBackground;
      }

      &.absolute {
        position: absolute;
        bottom: -9999px;
        width: calc(100% - 20px);
      }

      > strong {
        font-size: 120%;
        font-weight: $__fontWeightNormal;
        line-height: 150%;
      }

      > p {
        margin: 15px 0 5px;
        text-align: right;
        font-size: 120%;

        > a {
          display: inline-block;
          padding: 2px 7px;
          font-weight: $__fontWeightMedium;
          border-radius: 3px;
          margin: 0 3px;
          cursor: pointer;
          transition: background 0.5s;

          &:hover {
            background: rgba(0, 0, 0, 0.05);
          }

          &[href] {
            float: left;
          }
        }
      }

      > div.answer {
        margin-top: 20px;
        @include suggestion;

        p + p {
          margin-top: 10px;
        }
      }
    }
  }

  &.onlySuggestions {

    div.feedbackWrapper {
      display: none;
    }

    div.faq {
      display: none;
    }

    div.suggestedAnswers {
      max-height: none !important;

      &::before {
        display: none;
      }

      > a {
        display: block;
      }
    }
  }
}

@import "../../rtl/include/settings/support";